<?php
declare(strict_types=1);

namespace SixShop\Wechat;

use SixShop\Wechat\Model\ExtensionWechatUserModel;

readonly class WechatUser
{

    /**
     * 获取用户openid
     */
    public function openid(int $userID): ?string
    {
        return ExtensionWechatUserModel::where(['user_id' => $userID])->value('openid');
    }
}